/**
*	@file TNode.cpp
*
*	@brief this header file is defining table structure
*
*	@author li yuchen
*
*	@date 1/28/2011
*/  
#include "TNode.h"

string TNodeTypeToString(TNodeType type){
	switch(type){
	case PROC_TYPE:
		return "procedure";
	case STMT_LIST_TYPE:
		return "statement list";
	case OP_TYPE:
		return "operator";
	case VAR_TYPE:
		return "variable";
	case CONST_TYPE:
		return "constant";
	case ASSIGN_TYPE:
		return "assignment";
	case WHILE_TYPE:
		return "while statement";
	case IF_TYPE:
		return "if statement";
	case CALL_TYPE:
		return "call statement";
	case STMT_TYPE:
		return "statement ";
	case ROOT:
		return "root";
	}
	return "";
}